#include "StdAfx.h"
#include "MuObjectFactory.h"
#include "MuPlayer.h"

using namespace GameServer::Factorys;
using namespace GameServer::Objects::MuPlayer;

CMuObjectFactory::CMuObjectFactory()
{
}

CMuObjectFactory::~CMuObjectFactory()
{
}

CMuObject* CMuObjectFactory::CreateObject(MuObjectType type)
{
	CMuObject* muObject = nullptr;

	if( type == Player )
	{
		muObject = new CMuPlayer();
	}
	else if( type == Monster )
	{
		muObject = new CMuMonster();
	}
	else if( type == Npc )
	{
		muObject = new CMuNpc();
	}

	muObject->SetType(type);
	return muObject;
}